#pragma once

#include <string>

using namespace std;

class LinkedList
{
public:
	struct ListNode
	{
	public:
		ListNode( const string& theString, ListNode* pNext = NULL )
		{
			word = theString;
			pNextNode = pNext;
		}

		string word;
		ListNode* pNextNode;
	};

public:
	LinkedList();//default constructor
	~LinkedList();//destructor

	void addWord( const string& theWord );
	void removeWord( const string& theWord );
	void removeAllWords();

	string getReport() const;

   //Changed this from private to protected so that classes that inherit this class will be able to access this pointer.
protected:
	ListNode* mpHead;

};

/*
class BackwardLinkedList: public LinkedList
{
public:
	BackwardLinkedList();
	~BackwardLinkedList();

	void addWord( const string& theWord );

};*/